package com.qinhailin.portal.dbm.service;

import java.util.List;

import com.qinhailin.portal.dbm.po.SessionKilling;

/** 2019-11-23 22:25:32 批量生成 harrydeep@wardyan.top **/
public class DPListsessionkillingServiceImpl {

	@SuppressWarnings("unchecked")
	public List<SessionKilling> dp_listsessionkilling(Integer pCustID){

		return (List<SessionKilling>) com.jfinal.plugin.activerecord.Db.execute(new com.jfinal.plugin.activerecord.ICallback(){
			@Override
			public List<SessionKilling> call(java.sql.Connection conn) throws java.sql.SQLException {
				java.sql.CallableStatement proc = conn.prepareCall("{call dp_listsessionkilling(?)}");
				proc.setInt(1,pCustID);

				java.sql.ResultSet rs = proc.executeQuery();

				List<SessionKilling> list = new java.util.ArrayList<>();
				while(rs.next()){
					SessionKilling data = new SessionKilling();
					data.setSPID(rs.getInt("sPID"));
					data.setXStartTime(rs.getTimestamp("xStartTime"));
					list.add(data);

				}
				return list;
			}
		});
	}
}

